package com.axzhengxin.platform.afterloan.mapper;

import com.axzhengxin.platform.afterloan.domain.InventoryLoanInfo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * InventoryLoanInfoMapper
 * 存量业务表Mapper接口
 *
 * @author jiangnan
 * @date 2021/4/1
 */
public interface InventoryLoanInfoMapper {

    /**
     * 根据贷款合同号查询导入的存量业务数据
     *
     * @param loanContractNo 贷款合同号
     * @return 存量业务
     */
    InventoryLoanInfo selectInventoryLoanInfoByLoanContractNo(@Param("loanContractNo") String loanContractNo);

    /**
     * 查询存量业务
     *
     * @param id 存量业务ID
     * @return 存量业务
     */
    InventoryLoanInfo selectInventoryLoanInfoById(Long id);

    /**
     * 查询存量业务列表
     *
     * @param inventoryLoanInfo 存量业务
     * @return 存量业务集合
     */
    List<InventoryLoanInfo> selectInventoryLoanInfoList(InventoryLoanInfo inventoryLoanInfo);

    /**
     * 查询存量业务列表
     * 带数据权限过滤
     *
     * @param inventoryLoanInfo 存量业务
     * @return 存量业务集合
     */
    List<InventoryLoanInfo> selectInventoryLoanInfoListWithDataScope(InventoryLoanInfo inventoryLoanInfo);

    /**
     * 新增存量业务
     *
     * @param inventoryLoanInfo 存量业务
     * @return 结果
     */
    int insertInventoryLoanInfo(InventoryLoanInfo inventoryLoanInfo);

    /**
     * 修改存量业务
     *
     * @param inventoryLoanInfo 存量业务
     * @return 结果
     */
    int updateInventoryLoanInfo(InventoryLoanInfo inventoryLoanInfo);

    /**
     * 删除存量业务
     *
     * @param id 存量业务ID
     * @return 结果
     */
    int deleteInventoryLoanInfoById(Long id);

    /**
     * 批量删除存量业务
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    int deleteInventoryLoanInfoByIds(Long[] ids);

}
